<template>
	<view class="orderContent">
		<view class="bg"></view>
		<!-- 头部标题 -->
		<view class="title-header">
			<view class="title-header-main">
				<view class="">
					<uni-icons type="back" size="50rpx" color="white" @click="JumpReturnArrow"></uni-icons>
				</view>
				<view class="">
					<text>{{ arr.site_name }}</text>
				</view>
			</view>
		</view>
		<!-- 头部内容 -->
		<view class="slot-wrap">
			<view class="shopList">
				<view class="shop_top">
					<view class="topLeft">
						<image :src="'https://songcan.xyct1688.com/' + arr.logo" mode=""></image>
						<view class="shopText">
							<view class="shopName">{{ arr.site_name }}</view>
							<view class="monthNum">
								<text>☆ {{ arr.sub_num }} 销量：{{ arr.shop_sales }}</text>
							</view>
							<view class="price" @click="showSmegma" v-if="shop_reduction == []">
								<text class="pri_o">￥</text><text class="pri_s">26</text>
								<image src="../../static/order/vipIcon.png" mode=""></image>
								<text class="pri_t">会员领取</text>
							</view>
							<view class="" style="display: flex;">
								<view class="" v-for="(item, index) in shop_reduction" :key="index">
									<text class="shopManjian">满{{ item.money }}减{{ item.discount_money }}</text>
								</view>
							</view>
							<view class="monthNum">营业时间：{{ arr.start_time + '——' + arr.end_time }}</view>

							<view class="notices">
								{{ arr.notice }}
							</view>
						</view>
					</view>
					<view class="topRight">
						<view class="" @click="goCollect">
							<image src="../../static/order/collect.png" mode="" v-if="collect == 0"></image>
							<image src="https://i.hd-r.cn/0184b027ea3a667b3093c4e259a76ab0.png" mode="" v-if="collect == 1"></image>
						</view>
						<!-- <view class="clickIcon" @click="popupShowCoupon">
							<uni-icons type="bottom"></uni-icons>
						</view> -->
					</view>
				</view>
			</view>
		</view>
		<view class="empty" v-if="shop_reduction.length != 0 && shop_reduction == []"></view>
		<view class="emptys" v-else></view>
		<!-- 点餐，评价，商家 -->
		<view class="orderTab">
			<!-- style="display: flex;justify-content: space-between;" -->
			<view class="orderTab-main">
				<view class="tab-list" style="display: flex; padding: 0 19rpx;">
					<view :id="`id` + index" class="tab-item-wrapper" style="padding-right: 50rpx;" v-for="(item, index) in list"
						:key="index">
						<view class="tab-item" :class="current == index ? 'item-active' : ''" @click="tabsChange(index)">
							<view class="border_bottom">
								{{ item.name }}<text v-if="item.id == 2">({{ evaluate }})</text>
							</view>
						</view>
					</view>
				</view>
				<view class="search">
					<uni-search-bar radius="100" bgColor="white" @confirm="search" :focus="false" v-model="searchValue"
						clearButton="auto" cancelButton="none" placeholder="输入商品名称">
						<uni-icons slot="searchIcon" color="#999999" size="18" type="search" />
					</uni-search-bar>
				</view>
			</view>
			<view class="swiper-item" v-for="(v, i) in list" :key="i" v-if="swiperCurrent == 0">
				<view class="hotContent" v-show="i == 0">
					<!-- :hotList="hotList" -->
					<!-- <order-product :arr="arr" :ShoppingCartList="ShoppingCartList" @costs="costs"></order-product> -->
					<view class="hotContent-remai" v-if="hotSelling.count != 0">
						<view class="hotTitle">
							本店热卖
						</view>
						<view class="hotProduct">
							<view class="hotList" v-for="(item, index) in hotSelling.list" :key="index">
								<image :src="$image + item.sku_image" mode=""></image>
								<view class="productName">
									{{ item.goods_name }}
								</view>
								<view class="price">
									<view class="add" v-if="item.cart_id == shopitem.cart_id && shopitem.num > 0"
										@click.stop="shopJiab(item, shopitem.num)">-</view>
									<view class="money">￥{{ item.price }}</view>
									<view class="addProduce" @click.stop="addShoppingCart(item)">+</view>
								</view>
							</view>
						</view>
					</view>

					<view class="menuContent">
						<!-- 商品种类左边 -->
						<scroll-view :scroll-top="0" scroll-y="true" class="scroll-Y-left" show-scrollbar="true">
							<view class="left-aside">
								<view v-for="(item, index) in flist" :key="index" class="f-item b-b"
									:class="{ active: currentId === item.category_id }" @click="tabtap(item, index)">
									{{ item.category_name }}
								</view>
							</view>
						</scroll-view>
						<scroll-view :scroll-top="0" scroll-y="true" class="scroll-Y-right" show-scrollbar="true"
							@scrolltolower="scrolltolower" @scrolltoupper="scrolltoupper">
							<view class="right-aside">
								<view class="s-list" v-for="(item) in commodityList" :key="item.goods_id">
									<view class="t-list">
										<view class="t-item" @click="JumpCommodityDetails(item)">
											<image :src="$image + item.goods_image" mode="">
											</image>
											<view class="right">
												<view class="title">{{ item.goods_name }}</view>
												<view class="monthNum">
													<!-- 月销量 -->
													<text style="margin-left: 10rpx;">销量：{{ item.sale_num }}</text>
												</view>
												<view class="flex-box">
													<view class="">￥{{ item.price }}</view>
													<view
														style="display: flex;flex-direction: row;justify-content: space-between;align-items: center;">
														<view v-for="(shopitem) in shoppingCart" :key="shopitem.goods_id"
															style="display: flex;flex-direction: row;">
															<view class="add" v-if="item.goods_id == shopitem.goods_id"
																@click.stop="gou_wu_che_jian(shopitem)">-</view>
															<view style="flex-grow: 1;padding-left: 10px;padding-right: 10px;"
																v-if="item.goods_id == shopitem.goods_id">{{ shopitem.num }}</view>
														</view>
														<view class="add" @click.stop="addShoppingCart(item)">+</view>
													</view>

												</view>
											</view>
										</view>
									</view>
								</view>
							</view>
						</scroll-view>
					</view>
				</view>
			</view>
			<view class="icon-box-img" v-if="commodityList == [] && flist.length == 0">
				<img src="../../static/index/noResult.png" alt="">
				<view class="text">
					未查询到相关数据
				</view>
			</view>
			<!-- v-if="commodityNum==0" -->
			<view class="evaluateContent" v-if="swiperCurrent == 1">
				<!-- :goodsList="goodsList" :cateList="cateList" -->
				<!-- @shopEvaluateList="shopEvaluateList" -->
				<evaluate :arr="arr"></evaluate>
			</view>
			<view class="busShop" v-if="swiperCurrent == 2">
				<!-- :shopPhone="shopPhone"  :callNumber="callNumber" -->
				<!-- :imgList="imgList" -->
				<bus-shop :certificate="certificate" :arr="arr"></bus-shop>
			</view>
		</view>
		<!-- 底部操作菜单没有数据 -->
		<view class="buy" v-if="commodityNum == 0 && swiperCurrent !== 2">
			<view class="opt-in">
				<i class="Grey-shopping-cart"></i>
				<text class="Settlement-font">
					<text style="color:#aaa; font-size: 20rpx;padding-right: 20rpx;">配送费另算</text>
					<text style="color: #fff; font-size: 24rpx;">未选购商品</text>
				</text>
			</view>
			<view class="payment">
				<!-- <text class="paument-font">￥{{express.local.start_money}}起送</text> -->
				<text class="paument-font">￥{{ differFroms }}起送</text>
			</view>
		</view>
		<!-- 底部操作菜单有数据 -->
		<view class="buyer" v-if="commodityNum !== 0 && swiperCurrent !== 2">
			<view class="opter-in">
				<i @click="shopscat()" type="primary" class="Greyer-shopping-cart">
					<!-- <i>{{shoppingCart.length}}</i> -->
					<i>{{ commodityNum }}</i>
				</i>
				<text class="Settlementer-font">
					<text style="color:#aaa; font-size: 20rpx;padding-right: 20rpx;">配送费{{ express.local.delivery_money }}元</text>
					<text style="color: #000; font-size: 24rpx;">合计：￥
						<text style="color: #f14500;font-size: 30rpx;">{{ allPrice }}</text></text>
				</text>
			</view>
			<view class="paymenter">
				<!-- v-if="plus + Deliverycharge <= lifting" -->
				<text class="paumentertwo" v-if="allPrice >= differFroms" @click="settlement(shoppingCart)">去结算</text>
				<text class="paumenterone" v-if="allPrice < differFroms">差￥{{ differFrom }}起送</text>
			</view>
		</view>

		<!-- 会员红包兑换蒙层 -->
		<view class="">
			<!-- :busName="busName" :busMoney="busMoney" :num="num" :vipMonth="vipMonth" -->
			<!-- <smegma ref="smegma" :arrlist="arr"></smegma> -->
			<view>
				<u-mask :show="show" @click="show = false" :mask-click-able="false">
					<view class="warp">
						<view class="rect" @tap.stop>
							<view class="close" @click="show = false">X</view>
							<view class="title">
								是否兑换
							</view>
							<view class="little">
								现有六张月卡优惠券，兑换需使用<text class="num">{{ num }}</text>张
							</view>
							<view class="couponContent">
								<view class="coupon_left">
									<view class="left_container">
										<view class="contentBox">
											<text class="icon">￥</text><text class="vipMonth">{{ vipMonth }}</text>
											<view class="noDoor">
												无门槛
											</view>
										</view>
										<view class="text">
											月卡红包
										</view>
									</view>
								</view>
								<image src="../../static/index/to.png" mode=""></image>
								<view class="coupon_right">
									<view class="right_container">
										<view class="contentBox">
											<text class="icon">￥</text>
											<text class="vipMonth">{{ busMoney }}</text>
											<view class="noDoor">
												无门槛
											</view>
										</view>
										<view class="text">
											{{ arr.site_name }}
										</view>
									</view>
								</view>
							</view>
							<button class="uniButton" type="primary" @click="confirmExchange">确认兑换</button>
						</view>
					</view>
				</u-mask>

				<u-popup v-model="showCoupon" mode="bottom" border-radius="18" height="989rpx" :closeable="true">
					<view class="content_Cert">
						<view class="title">红包优惠</view>
						<view class="lineTwo">
							<text class="left_title">外卖红包</text>
							<text class="right_title">每单限一张，可叠加其他红包卡劵</text>
						</view>
					</view>
					<view class="">
						<!-- member -->
						<view class="main-item" v-for="(item, index) in shop_couponList.list" :key="index">
							<view class="notUsed">
								<view class="centent flexjcsb">
									<view class="threshold">
										<view class=""> ￥<text>{{ item.money }}</text> </view>
										<view class="preferentialThreshold">
											<!-- <text>无门槛</text> -->
											<text>{{ item.coupon_name }}</text>
										</view>
									</view>
									<view class="certificate">
										<view class="certificate-title"> {{ item.site_name }} </view>
										<view class="certificate-date">
											<!-- <text>2023.02.12</text>
						          <text>~</text> -->
											<text>{{ item.end_time | couponTime }}</text>到期
										</view>
									</view>
									<view class="centent-status">
										<view class="centent-status-ling" v-if="is_exist == 1">
											<view class=""> 立即 </view>
											<view class=""> 使用 </view>
										</view>
										<view class="centent-status-yi" v-else @click="shopCoupon(item)">
											领取
										</view>
									</view>
								</view>
							</view>
						</view>
					</view>
					<view class="left_title">
						优惠活动
					</view>
					<!-- v-for="(item,index) in popupList" :key="index" -->
					<view class="shopTextContent">
						<text class="shopTitle">满减</text>
						<text class="shopText" v-for="(item, index) in shop_reduction" :key="index">满{{ item.money }}元减{{
							item.discount_money }}元,</text>
					</view>
					<view class="shopTextContent">
						<text class="shopTitle">首单</text><text class="shopText">首单减5元</text>
					</view>
					<view class="shopTextContent">
						<text class="shopTitle">配送</text><text class="shopText">配送费 满2减1</text>
					</view>
					<view class="notice">
						公告：{{ arr.notice }}
					</view>
				</u-popup>
			</view>
		</view>
		<!-- 会员红包兑换蒙层 end-->

		<u-popup v-model="costShow" mode="bottom" border-radius="40">
			<!-- <view>出淤泥而不染，濯清涟而不妖</view> -->
			<view class="commodity">
				<view class="commodity-title">
					<view class="commodity-title-left">
						<text class="selectedCommodity">已选商品</text>
						<text class="pack">打包费</text>
						<text class="fee">{{ express.local.pack_money }} 元/份</text>
					</view>
					<view class="commodity-title-right" @click="emptyshoppingCart">
						清空
					</view>
				</view>
				<view class="commodity-main" v-for="(item, index) in shoppingCart" :key="index">
					<view class="commodity-main-image">
						<image :src="$image + item.sku_image" mode=""></image>
					</view>
					<view class="commodity-main-right">
						<view class="title">{{ item.goods_name }}</view>
						<view class="notes">{{ item.sku_name }}</view>
						<view class="price">
							<view class="price-left">
								<text>￥{{ item.discount_price }}</text>
								<text>￥{{ item.market_price }}</text>
							</view>
							<view class="price-right">
								<u-number-box v-model="item.num" :value="shoppingCartNum" :longPress="false"
									@plus="eventCommodityjia(item)" @minus="(e) => eventCommodityjian(e, item)"
									:disabled-input="true"></u-number-box>
							</view>
						</view>
					</view>
				</view>
			</view>
		</u-popup>
	</view>
</template>

<script>
import busShop from './busShop.vue';
import evaluate from './evaluate.vue';
// import smegma from '../smegma/smegma.vue'
// import res from "../../pages/Json.js";
// import loginVue from '../../pages_login/login/login.vue';
const $api = require('@/utils/request.js').API
import { debounce, throttle } from 'lodash';
export default {
	components: {
		// navbar
		// orderProduct,
		evaluate,
		busShop,
		// smegma
	},
	data() {
		return {
			site_id: '', // 店铺id
			arr: {}, // 店铺详情
			// shopPhone:'',	// 商家电话
			sizeCalcState: false,
			tabScrollTop: 0,
			currentId: 1,
			hotSelling: [], // 热卖
			flist: [], // 商品种类
			// 请求历史
			flistRequestList: [],
			// 储存左侧分类高度
			flistHeightList: [{}],
			commodityList: [], // 商品列表
			// commoditySku_id: [],
			commodityNum: 0, // 商品数量
			shoppingCartNum: 0,
			type: 'center', // 弹框
			cost: 0, // 购物车状态
			costShow: false,
			searchValue: '', // 搜索
			shoppingCart: [], // 购物车列表
			shop_reduction: [], // 店铺减免
			cart_ids: [],
			differFroms: 0, // 还差多少钱
			express: [], // 门店配送配置

			show: false,
			showCoupon: false,
			shop_couponList: [], // 店铺优惠卷列表
			is_exist: 0, // 优惠卷0 未领取，1 当天已领取
			showCertificate: false,
			collect: 0, //默认未收藏
			list: [{
				name: '点餐',
				id: 1
			}, {
				name: '评价',
				id: 2
			}, {
				name: '商家',
				id: 3
			}],
			evaluate: 0, // 评论数量
			// 因为内部的滑动机制限制，请将tabs组件和swiper组件的current用不同变量赋值
			current: 0, // tabs组件的current值，表示当前活动的tab选项
			swiperCurrent: 0, // 切换点餐、评价、商家
			certificateImg: //商家展示图
			{
				// img: require('../../static/index/img.png')
				img: 'https://188362.s21i.faiusr.com/2/ABUIABACGAAg8tD0gAUo5Oqa3gIwhAk47AY.jpg'
			},
			allPrice: 0, //全价
			$image: this.$image,
		}
	},
	async onLoad(options) {
		this.site_id = options.site_id
		// this.loadData();
		this.postStoreClassification() // 店铺的分类列表
		this.postShopDetails() // 店铺详情
		// this.postCommodityList() // 商品列表
		this.gethotSelling() // 热卖

		this.storeFullReduction() // 店铺满减
		this.shopWhetherToFollow() // 检测该店铺是否收藏
		this.evaluateList() // 评价
		this.storeDeliveryConfiguration() // 门店配送配置

		this.couponShop() // 我的优惠券（店铺）
		this.couponList() // 店铺优惠卷列表
		this.testingCanCollectStoreCoupons() // 检测是都可以领取店铺优惠券
		// this.platformMemberCouponList()	// 平台会员优惠券列表
		// this.platformCouponInformation()	// 平台优惠券信息
	},
	onShow() {
		if (this.is_exist == 1) {
			this.shopCoupon()
		}
		this.postShoppingCartNum() // 购物车数量
		// this.ShoppingCartList()
	},
	computed: {
		TotalPrice() {
			let num = 0
			this.shoppingCart.forEach(item => {
				// num += (item.price * item.num) + (this.express.local.pack_money * item.num)
				num += (item.price * item.num)
			})
			//打包费用
			if (this.express && this.express.local && this.express.local.pack_money) {
				num += Number(this.express.local.pack_money)
			}
			if (this.express && this.express.local && this.express.local.delivery_money) {
				num += Number(this.express.local.delivery_money)
			}
			// 加上配送费
			return num.toFixed(2)
		},

		differFrom() {
			// this.differFroms
			let num = this.allPrice < this.differFroms ? this.differFroms - this.allPrice : 0
			return num.toFixed(2)
		},
	},
	watch: {
		searchValue(e) {
			if (e == []) {
				this.postCommodityList()
			}
		},
	},
	filters: {
		couponTime(timestamp) {
			const date = new Date(timestamp * 1000)
			const year = date.getFullYear()
			const month = date.getMonth() + 1
			const day = date.getDate()
			const hours = date.getHours()
			const minutes = date.getMinutes()
			const seconds = date.getSeconds()
			const formattedTime = `${year}-${month}-${day}`
			return formattedTime
		}
	},

	methods: {
		// 商品滚动触底
		scrolltolower() {

			let index = this.flist.findIndex(item => item.category_id === this.currentId);
			console.log(index);
			console.log(this.flistRequestList);
			if (index !== -1) {
				if ((index + 1) >= this.flist.length) {
					return
				}
				if (this.flistRequestList[index + 1] == false) {
					this.currentId = this.flist[index + 1].category_id;
					this.postCommodityList()
					console.log('向下滚动');
				}

			} else {
				console.log("没找到该元素");
			}
		},

		// 商品向上滚动触顶
		scrolltoupper() {
			console.log('向上滚动');
			let index = this.flist.findIndex(item => item.category_id === this.currentId);
			if (index != 0) {
				this.currentId = this.flist[index - 1].category_id
				for (let i = 0; i < this.flist.length; i++) {
					this.flistRequestList[i] = false
				}
				this.commodityList = []
				this.postCommodityList()

			}
		},
		// 店铺的分类列表
		postStoreClassification() {
			let obj = {
				site_id: this.site_id
			}
			$api.postStoreClassification(obj).then(res => {
				if (res.data.code == 0) {
					this.flist = res.data.data
					for (let i = 0; i < this.flist.length; i++) {
						this.flistRequestList[i] = false
					}
					this.currentId = res.data.data[0].category_id
					this.postCommodityList()
				}
			})
		},
		// 店铺详情
		postShopDetails() {
			let obj = {
				site_id: this.site_id,
			}
			$api.postShopDetails(obj).then(res => {
				if (res.data.code == 0) {
					this.arr = res.data.data
				}
			})
		},
		// 商品列表
		postCommodityList(searchValue) {
			let obj = {
				site_id: this.site_id,
				shop_category_id: this.currentId,
				page_size: 1000,
				keyword: searchValue
			}
			$api.postCommodityList(obj).then(res => {
				if (res.data.code == 0) {
					this.commodityList.push(...res.data.data.list)
					// this.commoditySku_id = res.data.data.list
					let index = this.flist.findIndex(item => item.category_id === this.currentId);
					this.flistRequestList[index] = true

				}
			})
		},
		// 热卖
		gethotSelling() {
			$api.postCommodityList({
				site_id: this.site_id,
				shop_category_id: this.currentId,
				is_hot: 1,
			}).then(res => {
				if (res.data.code == 0) {
					this.hotSelling = res.data.data
				}
			})
		},
		// 商品详情
		JumpCommodityDetails(item) {
			uni.navigateTo({
				url: '../../pages/Productdetails/Productdetails?source=' + 0 + '&sku_id=' + item.sku_id + '&site_id=' + item.site_id
			})
		},
		// 加入购物车
		addShoppingCart(item) {
			$api.postAddShoppingCart({
				sku_id: item.sku_id,
				site_id: item.site_id,
				num: 1,
			}).then(res => {
				if (res.data.code == 0) {
					this.cost = 1
					this.ShoppingCartList()
					this.postShoppingCartNum()
					// this.postCommodityList()
				}
			})
		},

		//购物车减减
		gou_wu_che_jian(item) {
			let { cart_id, num } = item
			if (num - 1 == 0) {
				$api.postShoppingCartDel({
					cart_id: cart_id,
				}).then(res => {
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})
			} else {
				// 编辑
				$api.postShoppingCartEdit({
					cart_id: cart_id,
					num: num - 1
				}).then(res => {
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})
			}
		},


		shopJiab(objItem, numbers) {
			var cart_id = ''
			this.shoppingCart.forEach(item => {
				if (objItem.cart_id == item.cart_id) {
					cart_id = item.cart_id
				}
			})
			if (numbers - 1 == 0) {
				$api.postShoppingCartDel({
					cart_id: cart_id,
				}).then(res => {
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})
			} else {
				// 编辑
				$api.postShoppingCartEdit({
					cart_id: cart_id,
					num: numbers - 1
				}).then(res => {
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})
			}

		},
		// 购物车数量
		postShoppingCartNum() {
			$api.postShoppingCartNum({
				site_id: this.site_id,
			}).then(res => {
				// this.cost = 1
				this.commodityNum = res.data.data
				this.ShoppingCartList()
			})
		},
		// 购物车列表
		ShoppingCartList() {
			$api.postShoppingCartList({
				site_id: this.site_id,
			}).then(res => {
				if (res.data.code == 0) {
					this.shoppingCart = res.data.data
					this.actualamount()
				}
			})
		},
		// 清空购物车
		emptyshoppingCart() {
			let cart_id = []
			let _this = this
			this.shoppingCart.forEach(item => {
				cart_id.push(item.cart_id)
				this.cart_ids.push(item.cart_id)
			})
			uni.showModal({
				title: '您确定要清空购物车吗？',
				success: function (res) {
					if (res.confirm) {
						$api.postShoppingCartDel({
							token: uni.getStorageSync('token'),
							cart_id: cart_id.toString(),
						}).then(res => {
							uni.showToast({
								title: '清空购物车成功',
								duration: 2000
							})
							// uni.removeStorageSync('cart_id')
							_this.allPrice = 0
							_this.ShoppingCartList()
							_this.postShoppingCartNum()
						})
					} else if (res.cancel) {
						uni.showToast({
							title: '您取消了清空购物车',
							icon: 'none',
							duration: 2000
						})
					}
				}
			})
		},
		// 店铺满减
		storeFullReduction() {
			$api.postStoreFullReduction({
				site_id: this.site_id,
			}).then(res => {
				this.shop_reduction = res.data.data
			})
		},
		// 门店配送配置
		storeDeliveryConfiguration() {
			$api.postStoreDeliveryConfiguration({
				site_id: this.site_id
			}).then(res => {
				this.differFroms = Number(res.data.data.local.start_money)
				this.express = res.data.data
			})
		},
		// 已选商品
		shopscat() {
			this.costShow = true
			this.ShoppingCartList()
		},
		eventCommodityjia(item) {
			this.addShoppingCart(item)
		},
		// 减去商品
		eventCommodityjian(e, objItem) {
			let cart_id = ''
			this.shoppingCart.forEach(item => {
				if (objItem.cart_id == item.cart_id) {
					cart_id = item.cart_id
				}
			})
			if (e.value == 0) {
				$api.postShoppingCartDel({
					cart_id: cart_id,
				}).then(res => {
					console.log('删除成功');
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})

			} else {
				$api.postShoppingCartEdit({
					cart_id: cart_id,
					num: e.value
				}).then(res => {
					this.ShoppingCartList()
					this.postShoppingCartNum()
				})
			}
		},
		settlement(item) {
			uni.navigateTo({
				url: '../../pages/Firmorder/Firmorder?source=' + 0 + '&item=' + JSON.stringify(item) + '&xiang=' + 0 + '&deliveryMoney=' + this.express.local.delivery_money
			})
		},
		// tabs通知swiper切换
		tabsChange(index) {
			this.current = index;
			this.swiperCurrent = index;
		},
		//搜索
		search(e) {
			this.commodityList = []
			for (let i = 0; i < this.flist.length; i++) {
				this.flistRequestList[i] = false
			}
			this.currentId = null
			this.postCommodityList(e.value)
		},
		// 检测该店铺是否关注
		shopWhetherToFollow() {
			$api.postShopWhetherToFollow({
				// token: uni.getStorageSync('token'),
				site_id: this.site_id
			}).then(res => {
				this.collect = res.data.data == 1 ? true : false
			})
		},
		// 收藏
		goCollect() {
			this.collect = !this.collect;
			if (this.collect) {
				$api.postCollectShop({
					// token: uni.getStorageSync('token'),
					site_id: this.site_id
				}).then(res => {
					uni.showToast({
						title: '收藏成功',
						duration: 2000
					})
				})
			} else {
				$api.postCancellationCollectShop({
					// token: uni.getStorageSync('token'),
					site_id: this.site_id
				}).then(res => {
					uni.showToast({
						title: '取消收藏',
						icon: 'none',
						duration: 2000
					})
				})
			}
		},
		// 评价列表
		evaluateList() {
			$api.postShopEvaluateList({
				site_id: this.site_id
			}).then(res => {
				if (res.data.code == 0) {
					this.evaluate = res.data.data.count
				}
			})
		},


		// async loadData() {
		// 	let list = this.cateList;
		// 	list.forEach(item => {
		// 		if (!item.pid) {
		// 			// this.flist.push(item); //pid为父级id, 没有pid或者pid=0是一级分类
		// 		} else if (!item.picture) {
		// 			this.slist.push(item); //没有图的是2级分类
		// 		} else {
		// 			this.tlist.push(item); //3级分类
		// 		}
		// 	})
		// },
		//一级分类点击
		tabtap(item, index) {
			for (let i = 0; i < this.flist.length; i++) {
				this.flistRequestList[i] = false
			}
			this.commodityList = []
			this.currentId = item.category_id;
			this.postCommodityList()

		},
		certificate(v) {
			this.showCertificate = !this.showCertificate
		},
		// 会员领取
		showSmegma() {
			// this.$refs.smegma.show = true;
			this.show = true
		},
		// 打开红包优惠弹出框
		popupShowCoupon() {
			// this.$refs.smegma.showCoupon = true
			this.showCoupon = true
		},
		// 返回上一级页面
		JumpReturnArrow() {
			uni.navigateBack()
		},
		// 确认兑换
		confirmExchange() {
			this.show = false;
			this.showCoupon = true
		},
		// 店铺优惠券列表
		couponList() {
			$api.postCouponList({
				site_id: this.site_id,
				can_receive: 1,
			}).then(res => {
				this.shop_couponList = res.data.data
			})
		},
		// 我的店铺优惠券
		couponShop() {
			$api.postCouponShop({}).then(res => { })
		},
		// 领取店铺优惠券
		shopCoupon(item) {
			$api.postReceiveShopCoupon({
				coupon_type_id: item.coupon_type_id,
			}).then(res => {
				if (res.data.code == 0) {
				} else {
					this.is_exist = res.data.data.is_exist
					uni.showToast({
						title: res.data.message,
						icon: 'none',
						duration: 2000
					})
				}
			})
		},
		// 检测是都可以领取店铺优惠券
		testingCanCollectStoreCoupons() {
			$api.postTestingCanCollectStoreCoupons({
				coupon_type_id: ''
			}).then(res => {
			})
		},
		// 平台会员优惠券列表
		// platformMemberCouponList(){
		// 	$api.postPlatformMemberCouponList({
		// 		can_receive: 0,
		// 		type:0,
		// 	}).then(res => {
		// 	})
		// },
		// 平台优惠券信息
		// platformCouponInformation(){
		// 	$api.postPlatformCouponInformation({
		// 		platformcoupon_type_id: 7
		// 	}).then(res => {
		// 	})
		// }
		// 总价
		actualamount() {
			if (this.shop_reduction.length != 0) {
				let obj = this.shop_reduction.filter(item => item.money <= this.TotalPrice)
				if (obj.length != 0) {
					this.allPrice = this.TotalPrice - obj[obj.length - 1].discount_money
				} else {
					this.allPrice = this.TotalPrice
				}
			} else {
				this.allPrice = this.TotalPrice
			}
		},
	}
}
</script>

<style lang="less" scoped>
::v-deep .u-navbar-inner {
	align-items: flex-start;
	// padding-top: 48rpx;
}

::v-deep .uniButton {
	margin-top: 78rpx;
	width: 80%;
	height: 94rpx;
	background: #F2CB7C;
	border-radius: 47rpx;
}

.empty {
	height: 65rpx;
	// height: 25rpx;
}

.emptys {
	height: 25rpx;
}

// +
.add {
	display: flex;
	justify-content: center;
	align-items: center;
	// width: 31rpx;
	// height: 31rpx;
	width: 40rpx;
	height: 40rpx;
	// line-height: 40rpx;
	// line-height: 28rpx;
	// text-align: center;
	color: #fff;
	background: #F14500;
	border-radius: 50%;
}

.title-header {
	position: relative;
	display: flex;
	width: 750rpx;
	// height: 393rpx;
	height: 300rpx;
	background: linear-gradient(180deg, #F14500, #F69360);
	text-align: center;
	color: white;
	padding-top: 80rpx;

	view:first-child {
		padding: 0 0 0 29rpx;
	}

	view:last-child {
		display: flex;
		justify-content: center;
		width: 100%;

		text {
			font-size: 36rpx;
			font-family: PingFang SC;
			font-weight: 500;
			color: #FFFFFF;
			padding-right: 80rpx;
		}
	}
}

.slot-wrap {
	position: absolute;
	// margin-top: 120rpx;
	// margin-left: -9%;
	padding: 16rpx 24rpx 0 19rpx;
	width: 702rpx;
	min-height: 180rpx;
	top: 150rpx;
	left: 24rpx;
	background: #FFFFFF;
	border-radius: 10rpx;
	// z-index: 99999;
}

.orderContent {
	width: 100%;
	min-height: 100%;
	height: auto;
	background: #F9F9F9;
}

::v-deep .uni-searchbar {
	width: 300rpx;
	padding: 12rpx 18rpx 0 0;
}

.item-active {
	font-size: 28rpx;
	font-family: PingFang SC;
	font-weight: 500;
	color: #E54100;
	// height: 90rpx;
	border-bottom: 2px solid #F14500;
}

.orderTab {
	width: 100%;
	// margin-top: 65rpx;

	.orderTab-main {
		display: flex;
		justify-content: space-between;
		align-items: center;
		height: 120rpx;
	}
}

.hotContent {
	width: 100%;
	min-height: 442rpx;
	background: #FFFFFF;
	border-radius: 40rpx 40rpx 0rpx 0rpx;

	// padding: 20rpx 27rpx 0 21rpx;
	.hotContent-remai {
		padding: 20rpx 27rpx 0 21rpx;
	}
}

.shopList {
	display: flex;
	flex-direction: column;
	background: #fff;
	// min-height: 210rpx;
	background: #FFFFFF;
	border-radius: 8rpx;

	.shop_top {
		display: flex;
		justify-content: space-between;
		align-items: center;

		.shopText {
			display: flex;
			flex-direction: column;
			justify-content: space-around;
			margin-left: 24rpx;
		}

		.shopName {
			font-size: 30rpx;
			font-family: PingFang SC;
			font-weight: 500;
			color: #161415;
		}

		.shopNum,
		.shopMoney {
			font-size: 20rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #747474;
		}

		.monthNum {
			font-size: 20rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #989898;
		}

		.shopManjian {
			padding: 0 5rpx;
			margin-right: 6rpx;
			display: inline-block;
			// width: 122rpx;
			// width: 150rpx;
			height: 38rpx;
			border: 1px solid #E54202;
			opacity: 0.52;
			border-radius: 3rpx;
			font-size: 22rpx;
			text-align: center;
			font-family: PingFang SC;
			font-weight: 400;
			color: #E54202;
		}

		.notices {
			font-size: 20rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #9E9E9E;
			padding-bottom: 20rpx;
		}

		.school {
			line-height: 51rpx;
			text-align: center;
			background: #F14500;
			border-radius: 25rpx;
			font-size: 24rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #FFFFFF;
		}

		image {
			width: 142rpx;
			height: 142rpx;
			border-radius: 10rpx;
		}

		.long {
			margin-top: 50rpx;
			font-size: 20rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #989898;
		}

		.topRight {
			display: flex;
			flex-direction: column;
			justify-content: space-between;
			align-items: center;
			// padding: 27rpx 0 40rpx 0;
			margin: 0 25rpx 0 10rpx;

			image {
				width: 46rpx;
				height: 44rpx;
			}

			.clickIcon {
				margin-top: 50rpx;
				color: #565961;
			}
		}

		.topLeft {
			display: flex;
			justify-content: end;
		}

		.price {
			margin: 6rpx 0;
			display: flex;
			align-items: center;
			// width: 184rpx;
			width: 200rpx;
			height: 44rpx;
			background: #EED5A0;
			border-radius: 6rpx;

			image {
				width: 22rpx;
				height: 20rpx;
				margin: 0 7rpx 0 7rpx;
			}

			.pri_o {
				margin-top: 10rpx;
				font-size: 22rpx;
				color: #5F452C;
			}

			.pri_s {
				font-size: 32rpx;
				font-weight: 400;
				color: #5F452C;
			}

			.pri_t {
				font-size: 22rpx;
				font-weight: 400;
				color: #5F452C;
			}
		}
	}
}

.hotTitle {
	padding-left: 37rpx;
	width: 702rpx;
	height: 72rpx;
	line-height: 72rpx;
	font-size: 28rpx;
	font-weight: 400;
	color: #333333;
	background: url('../../static/index/hotFire.png') no-repeat center left;
	background-size: 26rpx 36rpx;
	border-bottom: 1rpx solid #EEEDE9;
}

.hotProduct {
	padding: 39rpx 0 24rpx 45rpx;
	display: flex;
	width: 705rpx;
	// height: 442rpx;
	height: 350rpx;
	overflow-x: scroll;
	border-radius: 40rpx 40rpx 0rpx 0rpx;

	.hotList {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: space-between;
		margin-right: 15rpx;
		width: 195rpx;
		height: 286rpx;
		border: 2px solid #F4F4F4;

		image {
			margin: 41rpx 30rpx;
			width: 136rpx;
			height: 89rpx;
			box-shadow: 0rpx 17rpx 30rpx 0rpx rgba(102, 70, 8, 0.15);
		}

		.productName {
			color: #333333;
			font-size: 26rpx;
		}

		.price {
			display: flex;
			justify-content: space-between;
			padding: 0 19rpx 22rpx 17rpx;
			width: 100%;
			font-size: 28rpx;
			line-height: 32rpx;

			.money {
				color: #E54302;
			}

			.addProduce {
				display: flex;
				justify-content: center;
				align-items: center;
				// width: 31rpx;
				// height: 31rpx;
				width: 40rpx;
				height: 40rpx;
				// line-height: 28rpx;
				// text-align: center;
				color: #fff;
				background: #F14500;
				border-radius: 50%;
			}
		}
	}
}

// 食品安全证书
.content_Cert {
	display: flex;
	flex-direction: column;
	align-items: center;

	.bookTitle {
		height: 107rpx;
		line-height: 107rpx;
		font-size: 34rpx;
		font-family: PingFang SC;
		font-weight: 500;
		color: #161415;
	}

	image {
		width: 637rpx;
		height: 478rpx;
	}
}

/* 底部操作菜单 */
.page-bottom {
	position: fixed;
	left: 26rpx;
	bottom: 50rpx;
	z-index: 95;
	display: flex;
	justify-content: space-between;
	align-items: center;
	width: 699rpx;
	height: 103rpx;
	background: #6D6D6D;
	// border-radius: 60rpx;
	border-radius: 100rpx;

	.page-left {
		width: 503rpx;
		display: flex;
		justify-content: space-around;
		align-items: center;
		padding-left: 44rpx;

		image {
			width: 59rpx;
			height: 53rpx;
		}
	}

	.p-big-btn {
		font-size: 24rpx;
		color: #fff;
	}

	.p-b-btn {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		font-size: 20rpx;
		color: #B6B6B6;
		height: 80rpx;

		.yticon {
			font-size: 40upx;
			line-height: 48upx;
			color: #B6B6B6;
		}

		&.active,
		&.active .yticon {
			color: #B6B6B6;
		}

		.icon-fenxiang2 {
			font-size: 42upx;
			transform: translateY(-2upx);
		}

		.icon-shoucang {
			font-size: 46upx;
		}
	}

	.action-btn-group {
		display: flex;
		width: 195rpx;
		height: 100%;
		overflow: hidden;
		// box-shadow: 0 20upx 40upx -16upx #fa436a;
		box-shadow: 0 60upx 60upx -16upx #fa436a;
		box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4);
		background: #353535;
		position: relative;

		.action-btn {
			display: flex;
			align-items: center;
			justify-content: center;
			width: 180upx;
			height: 100%;
			font-size: 32rpx;
			color: #B6B6B6;
			padding: 0;
			border-radius: 0;
			background: #F14500;
			border-radius: 0 100px 100rpx 0;
		}
	}
}

.menuContent {
	display: flex;
}

.scroll-Y-left,
.scroll-Y-right {
	height: 60vh;
	width: 165rpx;
}

.scroll-Y-right {
	// width: auto;
	flex: 1;

}

.left-aside {
	flex-shrink: 0;
	width: 165rpx;
	text-align: left;
	background-color: #F9F9F9;
	padding-bottom: 200rpx;
}

.f-item {
	display: flex;
	align-items: center;
	padding: 20rpx 32rpx;
	width: 100%;
	// height: 92rpx;
	text-align: left;
	font-size: 24rpx;
	// position: relative;
	font-family: PingFang SC;
	font-weight: 400;
	color: #5D5D5D;
	// overflow: hidden;
	// text-overflow: ellipsis;
	// white-space: nowrap;

	&.active {
		color: #F14500;
		background: #FFFFFF;
		box-shadow: 0rpx 0rpx 20rpx 0rpx rgba(102, 70, 8, 0.15);
	}
}

.right-aside {
	background: #f9f9f9;
	flex: 1;
	overflow: hidden;
	padding-left: 32rpx;
	padding-bottom: 200rpx;
	padding-right: 27rpx;
}

.s-item {
	display: flex;
	justify-content: flex-start;
	align-items: center;
	height: 92rpx;
	padding-top: 8upx;
	font-size: 28upx;
	color: #606266;
}

.t-list {
	width: 100%;
	background: #fff;
	padding-top: 12rpx;
	margin-bottom: 5px;


	&:after {
		content: '';
		flex: 99;
		height: 0;
	}
}

.t-item {
	display: flex;
	align-items: center;
	width: 100%;
	font-size: 30rpx;
	font-family: PingFang SC;
	font-weight: 400;
	color: #202020;
	padding: 0 34rpx 20rpx 0;

	.right {
		display: flex;
		flex-direction: column;
		justify-content: flex-end;
		width: 60%;
		margin-left: 17rpx;
		font-weight: 400;

		.flex-box {
			display: flex;
			justify-content: space-between;
			font-size: 30rpx;
			color: #FF5F3F;
		}

		.title {
			font-size: 30rpx;
			color: #202020;
		}

		.monthNum {
			margin-top: 20rpx;
			font-size: 22rpx;
			color: #AAAAAA;
		}

	}

	image {
		width: 200rpx;
		height: 200rpx;
		background: #FFEEE5;
		border-radius: 15rpx;
	}
}

/* 底部操作菜单 */
.page-bottom {
	.p-b-btn {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		font-size: 20rpx;
		color: #B6B6B6;
		height: 80rpx;

		.yticon {
			font-size: 40upx;
			line-height: 48upx;
			color: #B6B6B6;
		}

		&.active,
		&.active .yticon {
			color: #B6B6B6;
		}

		.icon-fenxiang2 {
			font-size: 42upx;
			transform: translateY(-2upx);
		}

		.icon-shoucang {
			font-size: 46upx;
		}
	}

	.action-btn-group {
		display: flex;
		width: 195rpx;
		height: 100%;
		border-radius: 0 100px 100rpx 0;
		overflow: hidden;
		box-shadow: 0 20upx 40upx -16upx #fa436a;
		box-shadow: 1px 2px 5px rgba(219, 63, 96, 0.4);
		background: #353535;
		position: relative;

		.action-btn {
			display: flex;
			align-items: center;
			justify-content: center;
			width: 180upx;
			height: 100%;
			font-size: 32rpx;
			color: #B6B6B6;
			padding: 0;
			border-radius: 0;
			background: transparent;
		}
	}
}

// 购物车
.buy {
	width: 700rpx;
	height: 103rpx;
	position: fixed;
	left: 26rpx;
	bottom: 50rpx;
	border-radius: 50rpx;
	background-color: #6d6d6d;
	overflow: hidden;

	.opt-in {
		// display: inline-block;
		float: left;
		width: 504rpx;
		height: 103rpx;
		background-color: #6d6d6d;
		position: relative;

		.Grey-shopping-cart {
			display: inline-block;
			width: 59rpx;
			height: 59rpx;
			background-image: url(../../static/details/ShoppingCart.png);
			background-position: center center;
			background-repeat: no-repeat;
			background-size: 59rpx 59rpx;
			margin-top: 25rpx;
			margin-left: 44rpx;
		}

		.Settlement-font {
			position: absolute;
			top: 43rpx;
			left: 157rpx;
			display: flex;
			justify-content: space-between;
			width: 260rpx;
			height: 23rpx;
			// margin-top: 43rpx;
			line-height: 23rpx;
			// margin-left: 54rpx;
		}
	}

	.payment {
		// float: left;
		display: flex;
		// align-items: center;
		// display: inline-block;
		width: 194rpx;
		height: 103rpx;
		background-color: #353535;
		text-align: center;

		.paument-font {
			// width: 109rpx;
			height: 29rpx;
			margin-top: 35rpx;
			margin-left: 36rpx;
			color: #b6b6b6;
			font-size: 24rpx;
			font-family: PingFang SC;
			font-weight: 400;
			line-height: 32rpx;
		}
	}
}

// 购物车有数据
.buyer {
	width: 700rpx;
	height: 103rpx;
	position: fixed;
	left: 26rpx;
	bottom: 50rpx;
	z-index: 1000;
	border-radius: 50rpx;
	background-color: #fff;
	overflow: hidden;

	.opter-in {
		// display: inline-block;
		float: left;
		width: 504rpx;
		height: 103rpx;
		background-color: #fff;
		position: relative;

		.Greyer-shopping-cart {
			display: inline-block;
			width: 59rpx;
			height: 59rpx;
			background-image: url(../../static/details/ShoppingCartfull.png);
			background-position: center center;
			background-repeat: no-repeat;
			background-size: 59rpx 59rpx;
			margin-top: 25rpx;
			margin-left: 44rpx;
			position: relative;

			i {
				width: 22rpx;
				height: 22rpx;
				position: absolute;
				right: 0;
				top: 0;
				background-color: red;
				color: #fff;
				text-align: center;
				line-height: 20rpx;
				font-size: 24rpx;
				border-radius: 50rpx;
			}
		}

		.Settlementer-font {
			position: absolute;
			top: 43rpx;
			left: 157rpx;
			display: flex;
			justify-content: space-between;
			// width: 305rpx;
			height: 25rpx;
			// margin-top: 43rpx;
			line-height: 25rpx;
			// margin-left: 54rpx;
		}
	}

	.paymenter {
		float: left;
		// display: inline-block;
		width: 194rpx;
		height: 103rpx;
		background-color: #f14500;
		text-align: center;
		position: relative;

		.paumenterone {
			display: flex;
			justify-content: center;
			align-items: center;
			height: 100%;
			color: #fff;
			font-size: 24rpx;
			font-family: PingFang SC;
			font-weight: 400;
			line-height: 29rpx;
		}

		.paumentertwo {
			display: flex;
			justify-content: center;
			align-items: center;
			height: 100%;
			color: #fff;
			font-size: 30rpx;
			font-family: PingFang SC;
			font-weight: 400;
			line-height: 29rpx;
		}
	}
}

// 购物车商品列表
.commodity {
	padding: 59rpx 32rpx 64rpx 41rpx;

	.commodity-title {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding-bottom: 48rpx;

		.commodity-title-left {
			font-size: 36rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #333333;

			.pack {
				font-size: 24rpx;
				color: #878787;
				padding-left: 20rpx;
			}

			.fee {
				font-size: 24rpx;
				color: #E64403;
				padding-left: 10rpx;
			}
		}

		.commodity-title-right {
			font-size: 26rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #A3A3A3;
		}
	}

	.commodity-main {
		display: flex;
		align-items: center;
		padding-bottom: 30rpx;

		.commodity-main-image {
			padding-right: 26rpx;

			image {
				width: 180rpx;
				height: 180rpx;
				border-radius: 10rpx;
			}
		}

		.commodity-main-right {
			.title {
				font-size: 36rpx;
				font-family: PingFang SC;
				font-weight: 400;
				color: #333333;
			}

			.notes {
				font-size: 24rpx;
				font-family: PingFang SC;
				font-weight: 400;
				color: #A3A3A3;
				padding: 30rpx 0 30rpx 0;
			}

			.price {
				display: flex;
				justify-content: space-between;
				align-items: center;
				width: 474rpx;

				.price-left {
					text:first-child {
						font-size: 36rpx;
						font-family: PingFang SC;
						font-weight: 500;
						color: #F14500;
					}

					text:last-child {
						font-size: 26rpx;
						font-family: PingFang SC;
						font-weight: 400;
						text-decoration: line-through;
						color: #A3A3A3;
					}
				}
			}
		}
	}
}

.warp {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;

	.rect {
		position: relative;
		display: flex;
		flex-direction: column;
		align-items: center;
		width: 75%;
		height: 737rpx;
		background: #FFFFFF;
		border-radius: 40rpx;

		.close {
			position: absolute;
			top: 44rpx;
			right: 56rpx;
			color: #8A8A8A;
		}

		.title {
			margin-top: 48rpx;
			font-size: 34rpx;
			font-family: PingFang SC;
			font-weight: 500;
			color: #161415;
		}

		.little {
			margin-top: 40rpx;
			font-size: 24rpx;
			font-family: PingFang SC;
			font-weight: 400;
			color: #7C7C7C;

			.num {
				color: #E74D0A
			}
		}

		.couponContent {
			display: flex;
			align-items: center;
			justify-content: space-around;
			margin-top: 22rpx;

			img {
				margin: 32rpx 15rpx 0 26rpx;
				width: 96rpx;
				height: 64rpx;
			}

			image {
				margin: 32rpx 15rpx 0 26rpx;
				width: 96rpx;
				height: 64rpx;
			}

			.coupon_right {
				position: relative;
				margin-top: 47px;
				width: 230rpx;
				height: 235rpx;
				background: #F2CB7C;
				border-radius: 23rpx;

				.right_container {
					position: absolute;
					top: -22rpx;
					left: 19rpx;
					display: flex;
					flex-direction: column;
					align-items: center;
					justify-content: space-between;
					width: 194rpx;
					height: 247rpx;
					background: #FFE4AC;
					border-radius: 23rpx;

					.contentBox {
						margin-top: 26rpx;

						.icon {
							font-size: 33rpx;
							font-family: PingFang SC;
							font-weight: 400;
							color: #836220;
							line-height: 33rpx;
						}

						.vipMonth {
							font-size: 79rpx;
							font-family: PingFang SC;
							font-weight: 400;
							color: #836220;
							line-height: 80rpx;
						}

					}

					.noDoor {
						font-size: 29rpx;
						font-family: PingFang SC;
						font-weight: 400;
						color: #8A6928;
						line-height: 50rpx;
					}

					.text {
						width: 100%;
						text-align: center;
						line-height: 81rpx;
						height: 81rpx;
						background: #F2CB7C;
						font-size: 24rpx;
						font-family: PingFang SC;
						font-weight: 500;
						color: #8F6714;
					}
				}
			}

			.coupon_left {
				position: relative;
				margin-top: 47px;
				width: 160rpx;
				height: 179rpx;
				background: #F2CB7C;
				border-radius: 23rpx;

				.left_container {
					position: absolute;
					top: -17rpx;
					left: 13rpx;
					display: flex;
					flex-direction: column;
					align-items: center;
					justify-content: space-between;
					width: 135rpx;
					height: 189rpx;
					background: #FFE4AC;
					border-radius: 23rpx;

					.contentBox {
						margin-top: 24rpx;

						.icon {
							font-size: 25rpx;
							font-family: PingFang SC;
							font-weight: 400;
							color: #836220;
							line-height: 33rpx;
						}

						.vipMonth {
							font-size: 60rpx;
							font-family: PingFang SC;
							font-weight: 400;
							color: #836220;
							line-height: 60rpx;
						}

					}

					.noDoor {
						font-size: 22rpx;
						font-family: PingFang SC;
						font-weight: 400;
						color: #8A6928;
						line-height: 30rpx;
					}

					.text {
						width: 100%;
						text-align: center;
						line-height: 81rpx;
						height: 81rpx;
						background: #F2CB7C;
						font-size: 24rpx;
						font-family: PingFang SC;
						font-weight: 500;
						color: #8F6714;
					}
				}
			}
		}
	}
}

.content_Cert {
	position: relative;
	font-weight: 400;

	.title {
		height: 107rpx;
		line-height: 107rpx;
		text-align: center;
		font-size: 34rpx;
		font-family: PingFang SC;
		font-weight: 500;
		color: #161415;
	}

	.lineTwo {
		margin-bottom: 20rpx;
	}

	.right_title {
		margin-left: 10rpx;
		font-size: 18rpx;
		color: #7C7C7C;
	}

}

.left_title {
	margin: 30rpx 0 0 30rpx;
	font-size: 28rpx;
	color: #161415;
}

.shopTextContent {
	margin: 15rpx 0 15rpx 30rpx;

	.shopTitle {
		display: inline-block;
		width: 73rpx;
		height: 38rpx;
		border: 1px solid #E54202;
		opacity: 0.52;
		border-radius: 3rpx;
		text-align: center;
		font-size: 22rpx;
		color: #F14500;
	}

	.shopText {
		margin-left: 12rpx;
		font-size: 22rpx;
		color: #7C7C7C;
	}
}

.notice {
	margin-left: 30rpx;
	// height: 100rpx;
	font-size: 24rpx;
	color: #9E9E9E;
}

// 优惠券
// 会员
.member {
	width: 708rpx;
	height: 208rpx;
	// background-image: url('../../static/my/giveServiceTo/member.png');
	background-size: 100% 100%;
	margin: auto;
}

// 未使用
.notUsed {
	width: 708rpx;
	height: 208rpx;
	background-image: url("../../static/my/giveServiceTo/notUsed.png");
	background-size: 100% 100%;
	margin: auto;

	.threshold {
		border-right: 2rpx dashed #d2d2d2;
		color: #F14500;
	}
}

.main-item {
	.centent {
		// position: absolute;
		width: 100%;
		height: 100%;

		// 门槛
		.threshold {
			width: 250rpx;
			text-align: center;
			font-size: 27rpx;
			font-family: PingFang SC;
			font-weight: 400;
			// color: #836220;

			view:first-child {
				text {
					font-size: 67rpx;
					font-family: PingFang SC;
					font-weight: 400;
					// color: #836220;
					color: #F14500;
				}
			}

			view:last-child {
				color: #f14500;
				text-align: center;
			}

			.preferentialThreshold {
				// color: #8a6928;
				color: #F14500;
			}
		}

		// 指定
		.certificate {
			.certificate-title {
				font-size: 32rpx;
				font-family: PingFang SC;
				font-weight: 400;
				color: #000000;
			}

			.certificate-date {
				font-size: 24rpx;
				font-family: PingFang SC;
				font-weight: 400;
				padding-top: 10rpx;
				color: #999999;

				// color: #836220;
				text {
					padding: 0 6rpx;
				}
			}
		}

		// 状态
		.centent-status {
			width: 100rpx;
			height: 100%;
			font-size: 26rpx;
			font-family: PingFang SC;
			font-weight: 400;

			.centent-status-ling {
				display: flex;
				// justify-content: center;
				align-items: center;
				height: 100%;
				color: #ffffff;
				text-shadow: 0rpx 1rpx 1rpx rgba(182, 140, 255, 0.5);
				// padding-left: 20rpx;
				padding-left: 10rpx;
			}

			.centent-status-yi {
				display: flex;
				justify-content: center;
				align-items: center;
				width: 85%;
				height: 100%;
				color: #FFFFFF;
			}
		}
	}
}

.icon-box-img {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	margin-top: 80rpx;
	text-align: center;

	img {
		width: 343rpx;
		height: 306rpx;
	}

	image {
		width: 343rpx;
		height: 306rpx;
	}

	.text {
		margin-top: 35rpx;
		font-size: 30rpx;
		font-family: PingFang SC;
		font-weight: 400;
		color: #C3C4C4;
		line-height: 30rpx;
	}
}
</style>